.import ../../src/read_matrix.s
.import ../../src/utils.s

.data
file_path: .asciiz "inputs/test_read_matrix/test_input.bin"

.text
main:
    # Read matrix into memory
    la a0, file_path
    addi sp, sp, -8
    addi a1, sp, 0
    addi a2, sp, 4
    jal ra, read_matrix

    # save values
    mv s0, a0 # pointer to matrix
    lw s1, 0(sp) # rows
    lw s2, 4(sp) # columns

    # print dims
    add a0, sp, x0
    li a1, 1
    li a2, 2
    jal ra, print_int_array

    # Print out elements of matrix
    mv a0, s0
    mv a1, s1
    mv a2, s2
    jal ra, print_int_array


    # Terminate the program
    jal ra, exit
